home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 2000 November: Tool Chest / Dev.CD Nov 00 TC Disk 2.toast / pc / sample code / overview / win2maccountersamples / 0. counter sources / ccounter.h < prev   
Encoding:
C/C++ Source or Header  |  2000-09-28  |  1.0 KB  |  35 lines

  1. /*
  2.     File:        CCounter.h
  3.  
  4.     Contains:    Sample code to accompany Chapter 12 of 
  5.                 "An Introduction to Macintosh Programming for Windows Programmers".
  6.                 
  7.     Written by:    Worldwide Developer Technical Support
  8.  
  9.     Copyright:    1999 Apple Computer, Inc., All Rights Reserved
  10.  
  11.       You may incorporate this sample code into your applications without
  12.       restriction, though the sample code has been provided "AS IS" and the
  13.       responsibility for its operation is 100% yours.  However, what you are
  14.       not permitted to do is to redistribute the source as "DSC Sample Code"
  15.       after having made changes. If you're going to re-distribute the source,
  16.      we require that you make it clear in the source that the code was
  17.     descended from Apple Sample Code, but that you've made changes.
  18.     
  19. */
  20. #pragma once
  21.  
  22. #include <PP_Types.h>    // Int32
  23.  
  24. // ==================================
  25. class CCounter {
  26. public:
  27.                     CCounter();
  28.     virtual         ~CCounter();
  29.     virtual    void     Increment();
  30.     virtual    void     Decrement();
  31.     virtual    Int32     GetValue();
  32.     virtual    void     SetValue(Int32 value);
  33. private:
  34.     Int32            mValue;
  35. };